Skip to content

feat: improve worker support#1312

Merged
oXtxNt9U merged 39 commits into
developfrom
feat/ipc/imporvements
May 29, 2026
Merged

feat: improve worker support#1312
oXtxNt9U merged 39 commits into
developfrom
feat/ipc/imporvements

Conversation

@sebastijankuzner
Copy link
Copy Markdown
Contributor

@sebastijankuzner sebastijankuzner commented May 27, 2026

Summary

Limit number of workers to 4 even if more CPU cores are available. It can be adjusted via MAINSAIL_CRYPTO_WORKER_COUNT ENV variable.

Fix boot and make getWorker sync. Improve performance by delegating requests to workers with lowest job number. Use round robin if job count is equal.

Improve worker error handling and error logging. Remove killed workers form pool.

Type improvements.

Checklist

  • Ready to be merged

@codecov
Copy link
Copy Markdown

codecov Bot commented May 27, 2026

Codecov Report

❌ Patch coverage is 13.03030% with 287 lines in your changes missing coverage. Please review.
✅ Project coverage is 56.10%. Comparing base (5993367) to head (df9e075).

Files with missing lines Patch % Lines
packages/kernel/source/ipc/subprocess.ts 17.47% 85 Missing ⚠️
packages/crypto-worker/source/worker.ts 16.39% 51 Missing ⚠️
packages/crypto-worker/source/worker-pool.ts 4.87% 39 Missing ⚠️
packages/evm-api-worker/source/worker.ts 12.90% 27 Missing ⚠️
packages/transaction-pool-worker/source/worker.ts 12.90% 27 Missing ⚠️
packages/crypto-worker/source/worker-handler.ts 0.00% 19 Missing ⚠️
packages/evm-api-worker/source/worker-handler.ts 0.00% 7 Missing ⚠️
...s/transaction-pool-worker/source/worker-handler.ts 0.00% 7 Missing ⚠️
packages/kernel/source/application.ts 0.00% 4 Missing ⚠️
packages/kernel/source/ipc/handler.ts 0.00% 4 Missing ⚠️
... and 9 more
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1312      +/-   ##
===========================================
+ Coverage    55.92%   56.10%   +0.17%     
===========================================
  Files          967      971       +4     
  Lines        64241    64870     +629     
  Branches      1580     1662      +82     
===========================================
+ Hits         35927    36394     +467     
- Misses       28085    28245     +160     
- Partials       229      231       +2     
Flag Coverage Δ
contracts 97.74% <ø> (?)
packages 55.81% <13.03%> (-0.11%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@oXtxNt9U oXtxNt9U merged commit ab6817c into develop May 29, 2026
21 of 23 checks passed
@oXtxNt9U oXtxNt9U deleted the feat/ipc/imporvements branch May 29, 2026 01:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants